org 0x0

start:
    MOV A,#0x36
	inc A
	MOV 0x20,A
	
	MOV 0x21,#0x87
	inc 0x21
	
	mov dptr,#0x1234
	inc dptr
	
	mov 0x22,#0x12
	mov R0,#0x22
	inc @R0
	
	mov 0x23,#0x12
	mov R1,#0x23
	inc @R1
	
	
	mov R0,#0x0
	mov R1,#0x1
	mov R2,#0x2
	mov R3,#0x3
	mov R4,#0x4
	mov R5,#0x5
	mov R6,#0x6
	mov R7,#0x7
	
	inc R0
	inc R1
	inc R2
	inc R3
	inc R4
	inc R5
	inc R6
	inc R7
	
	sjmp $
;for test
REG_SP     EQU 0x1000
REG_A      EQU 0x1001
REG_B      EQU 0x1002
REG_PSW    EQU 0x1003
REG_PC     EQU 0x1004
REG_DPTR   EQU 0x1005
CYCLE      EQU 0x1006
REG_R0     EQU 0x2000
REG_R1     EQU 0x2001
REG_R2     EQU 0x2002
REG_R3     EQU 0x2003
REG_R4     EQU 0x2004
REG_R5     EQU 0x2005
REG_R6     EQU 0x2006
REG_R7     EQU 0x2007
REG_END    EQU 0x2FFF
	org 0x600
	dw 0x20,0x37
	dw 0x21,0x88
	dw 0x22,0x13
	dw 0x23,0x13
		
	dw REG_SP,    0x7
	dw REG_A,     0x37
	dw REG_B,     0x0
	dw REG_PC,    0x32
	dw REG_DPTR,  0x1235
	dw CYCLE,     36
	dw REG_R0,    0x1
	dw REG_R1,    0x2
	dw REG_R2,    0x3
	dw REG_R3,    0x4
	dw REG_R4,    0x5
	dw REG_R5,    0x6
	dw REG_R6,    0x7
	dw REG_R7,    0x8
	dw REG_END
end
	